﻿using Modules.Attachment;
using Modules.Person;
using System.ComponentModel.DataAnnotations;
using System.Net.Mail;

namespace ManagementApi.Models.Person
{
    public class PersonContractForm
    {
        /// <summary>
        /// 主键 
        ///</summary>
        [Display(Name = "主键")]
        public int? Id { get; set; }
        /// <summary>
        /// 合同编号 
        ///</summary>
        [Display(Name = "合同编号")]
        [Required(ErrorMessage = "{0}不能为空")]
        public string Code { get; set; }
        /// <summary>
        /// 人员Id 
        ///</summary>
        [Display(Name = "人员Id")]
        [Required(ErrorMessage = "{0}不能为空")]
        public int PersonId { get; set; }
        /// <summary>
        /// 签订类型 
        ///</summary>
        [Display(Name = "签订类型")]
        [Required(ErrorMessage = "{0}不能为空")]
        public 合同签订类型 SigningType { get; set; }
        /// <summary>
        /// 人员姓名
        /// </summary>
        [Display(Name = "人员姓名")]
        public string? PersonName { get; set; }
        /// <summary>
        /// 人员身份证号
        /// </summary>
        [Display(Name = "人员身份证号")]
        public string? PersonCardNumber { get; set; }
        /// <summary>
        /// 企业Id 
        ///</summary>
        [Display(Name = "企业Id")]
        [Required(ErrorMessage = "{0}不能为空")]
        public int CorpId { get; set; }
        /// <summary>
        /// 企业名称 
        ///</summary>
        [Display(Name = "企业名称")]
        public string? CorpName { get; set; }
        /// <summary>
        /// 合同类型 
        ///</summary>
        [Display(Name = "合同类型")]
        [Required(ErrorMessage = "{0}不能为空")]
        public 合同类型 Type { get; set; }
        /// <summary>
        /// 合同签订日期 
        ///</summary>
        [Display(Name = "合同签订日期")]
        [Required(ErrorMessage = "{0}不能为空")]
        public DateTime SigningDate { get; set; }
        /// <summary>
        /// 合同起始日期 
        ///</summary>
        [Display(Name = "合同起始日期")]
        [Required(ErrorMessage = "{0}不能为空")]
        public DateTime StartDate { get; set; }
        /// <summary>
        /// 合同终止日期 
        ///</summary>
        [Display(Name = "合同终止日期")]
        [Required(ErrorMessage = "{0}不能为空")]
        public DateTime EndDate { get; set; }
        /// <summary>
        /// 工资计算方式 
        ///</summary>
        [Display(Name = "工资计算方式")]
        [Required(ErrorMessage = "{0}不能为空")]
        public 工资计算方式 SalaryCalculationMethod { get; set; }
        /// <summary>
        /// 工资标准 
        ///</summary>
        [Display(Name = "工资标准")]
        [Required(ErrorMessage = "{0}不能为空")]
        public decimal WageStandard { get; set; }
        /// <summary>
        /// 工资支付日期 
        ///</summary>
        [Display(Name = "工资支付日期")]
        [Required(ErrorMessage = "{0}不能为空")]
        public int SalaryPaymentDate { get; set; }
        /// <summary>
        /// 合同附件
        /// </summary>
        [Display(Name = "合同附件")]
        [Required(ErrorMessage = "{0}不能为空")]
        public IEnumerable<AttachmentsForm<int>> Attachments { get; set; }
    }
}